package com.wjerp.tplus.server.api.request;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import io.swagger.annotations.ApiParam;
import lombok.AllArgsConstructor;
import lombok.Data;
import org.springframework.util.StringUtils;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;


/**
 * @author lishuailei
 */
@Data
@AllArgsConstructor
@ApiModel("用户管理--分页查询")
public class QueryUserListRequest {

    @ApiModelProperty(value="用户名称")
    private String name;
    @ApiModelProperty(value="用户名")
    private String userName;
    @ApiModelProperty(value="用户状态")
    private Boolean status;
    @ApiModelProperty(value="开始时间区间")
    private List<String> createdTimeRange;

    @ApiModelProperty(value="页码")
    private Integer current;
    @ApiModelProperty(value="每页记录数")
    private Integer pageSize;

    public String getName() {
        return StringUtils.isEmpty(name) ? "" : name;
    }

    public String getUserName() {
        return StringUtils.isEmpty(userName) ? "" : userName;
    }

    public Boolean getStatus() {
        return status;
    }
}
